package com.wuzheng.wisgo.sanitation.cloud.repository.mapper.plan;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.wuzheng.wisgo.sanitation.cloud.model.plan.param.TimeSlotParam;
import com.wuzheng.wisgo.sanitation.cloud.model.plan.pojo.JobPlanVehicleDTO;
import com.wuzheng.wisgo.sanitation.cloud.repository.builder.plan.JobPlanBuilder;
import com.wuzheng.wisgo.sanitation.cloud.repository.entity.plan.JobPlanVehicle;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.SelectProvider;

import java.util.List;

/**
 * 道路作业计划与车辆关联 Mapper 接口
 *
 * @author hoipang
 * @since 2019-12-19
 */
public interface JobPlanVehicleMapper extends BaseMapper<JobPlanVehicle> {

    @SelectProvider(type = JobPlanBuilder.class, method = "buildJobPlanVehicleDTOSql")
    List<JobPlanVehicleDTO> listVehicles(@Param("code") String code, @Param("timeSlots") List<TimeSlotParam> timeSlotParams);

}
